<script src="<?php echo base_url()?>/public/assets/js/laydate/laydate.js" type="text/javascript"></script>
<div class="row">
	<div class="col-sm-12">
	<form class="well form-search" method="get" action="/admin/summaryorder" id="formid">
		<input type="hidden" value="ok" name="search" />
		<div class="ztle">
			<div class="zsearch">
		    	支付时间:
		        <input class="ztleinput zia" placeholder="请输入开始时间" name="start_time" id="start_time" value="<?php echo $_REQUEST['start_time']?>" onclick="laydate({istime: true, format: 'YYYY-MM-DD'})">
		        至
		        <input class="ztleinput zib" placeholder="请输入结束时间" name="stop_time" id="stop_time" value="<?php echo $_REQUEST['stop_time']?>" onclick="laydate({istime: true, format: 'YYYY-MM-DD'})">
		        是否支付:
		        <select class="zysele" name="ispay" id="ispay">
		        	<option value="">请选择</option>
		            <option value="1" <?php if($_REQUEST['ispay'] == 1)echo 'selected'?>>已支付</option>
		            <option value="2" <?php if($_REQUEST['ispay'] == 2)echo 'selected'?>>未支付</option>
		        </select>
		        关键词:
		        <input class="ztleinput zia" placeholder="学生或园所" name="keyword" id="keyword" value="<?php echo $_REQUEST['keyword']?>" autocomplete="off">
		        <input type="submit" class="searchbtn" value="搜 索" style="height: 30px">
		        <a href="javascript:daochu();" class="searchbtn">导出</a>
		        <br><br>
		        <p><span>订单数：<?php echo $order_total?>&nbsp;&nbsp;&nbsp;&nbsp;</span>
		        <span>总金额：￥<?php echo number_format($money,2)?>元&nbsp;&nbsp;&nbsp;&nbsp;</span>
		        <span>总课时：<?php echo number_format($hours)?>&nbsp;&nbsp;&nbsp;&nbsp;</span>
		        <span>已上课时：<?php echo number_format($hours-$surplus_hours)?>&nbsp;&nbsp;&nbsp;&nbsp;</span>
		        <span>剩余课时：<?php echo number_format($surplus_hours)?></span></p>
		    </div>
		</div>
		</form>
		<div class="space"></div>
		<table width="100%" class="table table-striped table-bordered table-hover">
			<tr>
			    <th height="30">ID</th>
				<th>学生</th>
				<th>电话</th>
				<th height="30">课程</th>
				<th>金额</th>
				<th>状态</th>
				<th>支付时间</th>
				<th>总课时</th>
				<th>剩余课时</th>
				<th>地区</th>
				<th>市区</th>
				<th>园所</th>
				<th height="30">操作</th>
			</tr>
			<?php if(!empty($order_list)){foreach ($order_list as $key=>$val){?>
			<tr>
			  <td height="30"><?php echo $val['id']?></td>
			  <td><?php echo $val['baby_name']?></td>
			  <td><?php echo $val['link_mobile']?></td>
			  <td height="30"><?php echo $val['cp_title']?></td>
			  <td><?php echo $val['pay_fee']?></td>
			  <td><?php echo $order_status[$val['status']]?></td>
			  <td><?php echo $val['pay_time']?></td>
			  <td><?php echo $val['hours']?></td>
			  <td><?php echo $val['surplus_hours']?></td>
			  <td><?php echo $val['area_title']?></td>
			  <td><?php echo $val['city_title']?></td>
			  <td><?php echo $val['nursery_title']?></td>
			  <td height="30">
			  	<a href='/admin/summaryorder/info?id=<?php echo $val['id']?>&status=1'>详情</a>			  </td>
		  </tr>
		  <?php }}else{?>
			<tr>
			  <td height="30" colspan="13"><div align="center"><?php echo $error;?></div></td>
		  </tr>
		  <?php }?>
	  </table>
		
		<div class="float_right">
			<?php echo $pagelink;?>
		</div>
	</div>
</div>
<script type="text/javascript">

</script>
<!--content-->